package MyGO.controller;

import MyGO.Data.GlobalData;
import MyGO.controller.MyController.MyButton;
import MyGO.entity.Doctor;
import javafx.fxml.FXML;
import javafx.scene.control.Label;
import javafx.scene.layout.AnchorPane;
import javafx.scene.layout.HBox;
import javafx.scene.layout.VBox;

import java.io.IOException;

public class Doctor_main_viewController {
    private Doctor doctor;
    private String filtDoctorID;

    public Doctor_main_viewController() {
        this.doctor = GlobalData.doctor;
    }

    @FXML
    private VBox doctor_main_l;

    @FXML
    private AnchorPane doctor_main_r;

    @FXML
    private HBox doctor_main_root;

    @FXML
    private Label lable;

    @FXML
    public void initialize() throws IOException {
        System.out.println("transtlation");
        if (doctor == null) {
            filtDoctorID = null;
        } else {
            filtDoctorID = doctor.getId();
        }
//        MyButton button = new MyButton("患者查看", "doctor1.png", "tableView.fxml", doctor_main_r,
//                "label_way", "患者查看", "未叫号", filtDoctorID, "1");
//        doctor_main_l.getChildren().add(button);
//
//
//        MyButton button1 = new MyButton("检查申请", "doctor1.png", "check_doctor_view.fxml", doctor_main_r,
//                "label_way", "检查申请", null, doctor.getDepartment().toString(), "2");
//        doctor_main_l.getChildren().add(button1);
//
//        MyButton button2 = new MyButton("看诊记录", "doctor1.png", "check_doctor_view.fxml", doctor_main_r,
//                "label_way", "在诊患者", "已检查", filtDoctorID, "1");
//        doctor_main_l.getChildren().add(button2);
    }

}
